CREATE TABLE DAC_ISSUE
(
  ISSUE_ID    int   NOT NULL    AUTO_INCREMENT,
  ISSUE_TITLE    nvarchar(255)   NOT NULL    ,
  ISSUE_DESC    nvarchar(2000)   NULL    ,
  ISSUE_STS    int   NOT NULL    ,
  ISSUE_TYP    nvarchar(50)   NULL    ,
  ISSUE_OWNR    nvarchar(50)   NULL    ,
  ISSUE_PRGS    decimal(18, 2)   NULL    ,
  CREATE_TM    datetime   NOT NULL    ,
  ISSUE_LOCKED    int   NULL    ,
    CONSTRAINT PK_DAC_ISSUE PRIMARY KEY (ISSUE_ID)
)
;

CREATE TABLE DAC_USER
(
  USER_ID    nvarchar(50)   NOT NULL    ,
  USERNAME    nvarchar(50)   NOT NULL    ,
  FULLNAME    nvarchar(255)   NULL    ,
  USER_PWD    nvarchar(50)   NULL    ,
  CHANGINGPWD    int   NULL    ,
  USERLOCKED    int   NULL    ,
  LASTLOGIN    datetime   NULL    ,
  USER_DESC    nvarchar(2000)   NULL    ,
    CONSTRAINT PK_DAC_USER PRIMARY KEY (USER_ID)
)
;

CREATE TABLE DAC_LINE
(
  POINT_ID    int   NOT NULL    AUTO_INCREMENT,
  POINT    nvarchar(50)   NULL    ,
    CONSTRAINT PK_DAC_LINE PRIMARY KEY (POINT_ID)
)
;

CREATE TABLE DAC_MUTIPLEKEYS
(
  DAC_KEY1    nvarchar(50)   NOT NULL    ,
  DAC_KEY2    nvarchar(50)   NOT NULL    ,
  DAC_VALUE1    nvarchar(50)   NULL    ,
  DAC_VALUE2    nvarchar(50)   NULL    ,
    CONSTRAINT PK_DAC_MUTIPLEKEYS PRIMARY KEY (DAC_KEY1, DAC_KEY2)
)
;

